import Vue from 'vue'
import VXETable from 'vxe-table'
import VXETablePluginAntd from 'vxe-table-plugin-antd'
import 'vxe-table-plugin-antd/dist/style.css'
import './xtable.scss'
import DictSelect from '@/components/select/DictSelect'
Vue.use(VXETable)
VXETable.use(VXETablePluginAntd)
Vue.component(DictSelect.name, DictSelect)
VXETable.renderer.add('DictSelect', {
  // 激活时自动聚焦
  autofocus: '.dict-select',
  // 可编辑激活模板
  renderEdit (h, renderOpts, params) {
    return [
      <dict-select class="dict-select" params={ params } renderOpts={ renderOpts }></dict-select>
    ]
  }
})
